<!doctype html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">

<head>
<base th:href="@{/}">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta http-equiv="pragma" content="no-cache" />
<meta http-equiv="cache-control" content="no-cache" />
<meta http-equiv="expires" content="0" />
<title>授权管理</title>
<th:block th:include ="commHeaderInclude::commHead"></th:block>
<th:block th:include ="commHeaderInclude::formPageComm"></th:block>
<th:block th:include ="commHeaderInclude::listPageComm"></th:block>
</head>

<body class="ht">
<th:block th:include="commHeaderInclude::loading"></th:block>
	<div class="tabTitle"><span><i class="mdi mdi-menu-up"></i>授权管理</span></div>
	<div class="content-wrapper">
		<div class="breadCrumb">
			<i class="mdi mdi-map-marker"></i>
			<span><span th:text="${session.mcpName}"></span><i class="mdi mdi-chevron-double-right"></i>信息管理<i class="mdi mdi-chevron-double-right"></i>授权管理</span>
		</div>
		<form name="searchForm" id="searchForm" method="post">
			<div class="card mb-3">
				<div class="card-body">
					<h4 class="card-title"><span>按条件查询授权信息</span></h4>
					<div class="module searchModule" th:object="${vo.dto}">
						<ul class="mb-3">
<!--							<li><label>医保统筹区</label>-->
<!--								<div role="SelectGroup" data-options="url:'/mcp/base/area/',defaultText:'全部'">-->
<!--									<select name="province">-->
<!--										<option th:value="*{province}" class="selected" selected></option>-->
<!--									</select>-->
<!--									<select name="city" style="width: auto">-->
<!--										<option th:value="*{city}" class="selected" selected></option>-->
<!--									</select>-->
<!--									<select name="county" style="width: auto">-->
<!--										<option th:value="*{county}" class="selected" selected></option>-->
<!--									</select>-->
<!--								</div>-->
<!--							</li>-->
							<li>
								<label>资金方名称</label>
								<div><input type="text" name="bankOrgName" th:value="*{bankOrgName}" /></div>
							</li>
							<li>
								<label>授权书编号</label>
								<div><input type="text" name="authNo" th:value="*{authNo}" /></div>
							</li>
							<!--
							<li><label>中征放款流水编号</label><input type="text" th:value="*{bargainCode}"  name="bargainCode" placeholder="输入编号" /></li>
							<li><label>资金方</label><input type="text" th:value="*{orgName}" name="orgName" placeholder="输入机构名称" /></li>
							<li><label>中征融资申请编号</label><input type="text" th:value="*{financingCode}"  name="financingCode" placeholder="输入编号" /></li>
							<li>
								<label>普惠业务</label>
								<select  name="preferntialType" id="preferntialType">
									<option th:value="*{preferntialType}" value=""></option>
								</select>
							</li>
							<li>
								<label>放款时间</label>
								<input class="ht_dateInput" type="text" name="loanDateBegin" th:value="*{loanDateBegin}" placeholder="开始日期" data-options="endSelector:'[name=loanDateEnd]'" />
								<span class="ht_dateText d-inlineBlock">至</span>
								<input class="ht_dateInput" type="text" name="loanDateEnd" th:value="*{loanDateEnd}" placeholder="结束日期" data-options="startSelector:'[name=loanDateBegin]'"/>
							</li>
							<li>
								<label>到期时间</label>
								<input class="ht_dateInput" type="text" name="limitDateBegin" th:value="*{limitDateBegin}" placeholder="开始日期" data-options="endSelector:'[name=limitDateEnd]'" />
								<span class="ht_dateText d-inlineBlock">至</span>
								<input class="ht_dateInput" type="text" name="limitDateEnd" th:value="*{limitDateEnd}" placeholder="结束日期" data-options="startSelector:'[name=limitDateBegin]'"/>
							</li>
							<li>
								<label>业务类型</label>
								<select name="businessType" id="businessType">
									<option th:value="*{businessType}"></option>
								</select>
							</li>
							-->
						</ul>
						<div class="searchBtnContainer">
							<input class="btn btn-primary" type="submit" id="search" value="查询">
							<input class="btn btn-clear" type="clear" role="ClearButton" value="清空">
						</div>
					</div>
				</div>
			</div>
		</form>
		<form class="listForm" id="listForm" method="post">
			<div class="card mb-3">
				<div class="card-body">
					<h4 class="card-title">
						授权信息列表
						<!--<a href="/mcp/hos/auth/create/" target="windowFrame" class="btn btn-primary float-right mr-0"><i class="mdi mdi-table-edit"></i>新建</a>-->
					</h4>
					<div class="alert alert-warning"><i class="mdi mdi-alert-circle"></i>如对查询行为有异议，请尽快终止相关授权。</div>
					<div class="module">
						<div>
						<table cellpadding="0" cellspacing="0" class="hTable">
							<thead>
								<tr>
									<th>序号</th>
									<th>医保统筹区</th>
									<th>资金方名称</th>
									<th>授权书</th>
									<th>授权状态</th>
									<th>查询次数</th>
									<th>操作</th>
								</tr>
							</thead>
							<tbody>
								<tr th:each="li,item:${vo.page.list}">
									<td th:text="${item.index+vo.page.startRow}">1</td>
									<td th:text="${li.areaName}">医保统筹区</td>
									<td><a class="textLink-primary" role="openFrameWindow" th:href="@{'base/bank/detail?id='+${li.bankOrgId}}" th:text="${@util.fStr(li.bankOrgName)}">资金方名称</a></td>
									<td><a th:href="@{'base/auth/detail?id='+${li.id}+'&aid='+${li.aid}}" class="textLink-primary" role="openFrameWindow"  th:text="${li.authNo}" >授权书</a></td>
									<td th:text="${li.authStatusStr}">授权状态</td>
									<td><a th:href="@{'hos/payLog/?authId='+${li.id}}" class="textLink-primary" role="openFrameWindow" th:text="${li.queryCount}" >查询次数</a></td>
									<td><a class="btn btn-outline-primary btn-sm" role="openFrameWindow" th:classappend="${(li.authStatus=='2' || li.authStatus=='3') ? 'disabled' : ''}" th:href="@{${(li.authStatus=='2' || li.authStatus=='3')?'':'hos/auth/stop?id='+li.id+'&aid='+li.aid}}" >终止授权</a></td>
								</tr>
							</tbody>
						</table>
						<div class="noneRecord" th:if="${vo.page.total==0}">查无记录！</div>
						</div>
						<th:block th:include="commHeaderInclude::pageInfoComm"></th:block>
					</div>
				</div>
			</div>
		</form>
	</div>
</body>
<script>
	var page=new ListPage();
	page.init();
	//seajs.use("/mcp/hos/bargainBill/js/list");
</script>
</html>